3.1.47 \(\int \frac {a+b x+c x^2}{x^3 \sqrt {-1+d x} \sqrt {1+d x}} \, dx\)

Optimal. Leaf size=83 \[ \frac {1}{2} \left (a d^2+2 c\right ) \tan ^{-1}\left (\sqrt {d x-1} \sqrt {d x+1}\right )+\frac {a \sqrt {d x-1} \sqrt {d x+1}}{2 x^2}+\frac {b \sqrt {d x-1} \sqrt {d x+1}}{x} \]

________________________________________________________________________________________

Rubi [A]  time = 0.19, antiderivative size = 129, normalized size of antiderivative = 1.55, number of steps used = 6, number of rules used = 6, integrand size = 32, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.188, Rules used = {1610, 1807, 807, 266, 63, 205} \begin {gather*} \frac {\sqrt {d^2 x^2-1} \left (a d^2+2 c\right ) \tan ^{-1}\left (\sqrt {d^2 x^2-1}\right )}{2 \sqrt {d x-1} \sqrt {d x+1}}-\frac {a \left (1-d^2 x^2\right )}{2 x^2 \sqrt {d x-1} \sqrt {d x+1}}-\frac {b \left (1-d^2 x^2\right )}{x \sqrt {d x-1} \sqrt {d x+1}} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(a + b*x + c*x^2)/(x^3*Sqrt[-1 + d*x]*Sqrt[1 + d*x]),x]

[Out]

-(a*(1 - d^2*x^2))/(2*x^2*Sqrt[-1 + d*x]*Sqrt[1 + d*x]) - (b*(1 - d^2*x^2))/(x*Sqrt[-1 + d*x]*Sqrt[1 + d*x]) +
 ((2*c + a*d^2)*Sqrt[-1 + d^2*x^2]*ArcTan[Sqrt[-1 + d^2*x^2]])/(2*Sqrt[-1 + d*x]*Sqrt[1 + d*x])

Rule 63

Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> With[{p = Denominator[m]}, Dist[p/b, Sub
st[Int[x^(p*(m + 1) - 1)*(c - (a*d)/b + (d*x^p)/b)^n, x], x, (a + b*x)^(1/p)], x]] /; FreeQ[{a, b, c, d}, x] &
& NeQ[b*c - a*d, 0] && LtQ[-1, m, 0] && LeQ[-1, n, 0] && LeQ[Denominator[n], Denominator[m]] && IntLinearQ[a,
b, c, d, m, n, x]

Rule 205

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]*ArcTan[x/Rt[a/b, 2]])/a, x] /; FreeQ[{a, b}, x]
&& PosQ[a/b]

Rule 266

Int[(x_)^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Dist[1/n, Subst[Int[x^(Simplify[(m + 1)/n] - 1)*(a
+ b*x)^p, x], x, x^n], x] /; FreeQ[{a, b, m, n, p}, x] && IntegerQ[Simplify[(m + 1)/n]]

Rule 807

Int[((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))*((a_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> -Simp[((e*f - d*g
)*(d + e*x)^(m + 1)*(a + c*x^2)^(p + 1))/(2*(p + 1)*(c*d^2 + a*e^2)), x] + Dist[(c*d*f + a*e*g)/(c*d^2 + a*e^2
), Int[(d + e*x)^(m + 1)*(a + c*x^2)^p, x], x] /; FreeQ[{a, c, d, e, f, g, m, p}, x] && NeQ[c*d^2 + a*e^2, 0]
&& EqQ[Simplify[m + 2*p + 3], 0]

Rule 1610

Int[(Px_)*((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_))^(p_.), x_Symbol] :> Dist[((
a + b*x)^FracPart[m]*(c + d*x)^FracPart[m])/(a*c + b*d*x^2)^FracPart[m], Int[Px*(a*c + b*d*x^2)^m*(e + f*x)^p,
 x], x] /; FreeQ[{a, b, c, d, e, f, m, n, p}, x] && PolyQ[Px, x] && EqQ[b*c + a*d, 0] && EqQ[m, n] &&  !Intege
rQ[m]

Rule 1807

Int[(Pq_)*((c_.)*(x_))^(m_)*((a_) + (b_.)*(x_)^2)^(p_), x_Symbol] :> With[{Q = PolynomialQuotient[Pq, c*x, x],
 R = PolynomialRemainder[Pq, c*x, x]}, Simp[(R*(c*x)^(m + 1)*(a + b*x^2)^(p + 1))/(a*c*(m + 1)), x] + Dist[1/(
a*c*(m + 1)), Int[(c*x)^(m + 1)*(a + b*x^2)^p*ExpandToSum[a*c*(m + 1)*Q - b*R*(m + 2*p + 3)*x, x], x], x]] /;
FreeQ[{a, b, c, p}, x] && PolyQ[Pq, x] && LtQ[m, -1] && (IntegerQ[2*p] || NeQ[Expon[Pq, x], 1])

Rubi steps

\begin {align*} \int \frac {a+b x+c x^2}{x^3 \sqrt {-1+d x} \sqrt {1+d x}} \, dx &=\frac {\sqrt {-1+d^2 x^2} \int \frac {a+b x+c x^2}{x^3 \sqrt {-1+d^2 x^2}} \, dx}{\sqrt {-1+d x} \sqrt {1+d x}}\\ &=-\frac {a \left (1-d^2 x^2\right )}{2 x^2 \sqrt {-1+d x} \sqrt {1+d x}}+\frac {\sqrt {-1+d^2 x^2} \int \frac {2 b+\left (2 c+a d^2\right ) x}{x^2 \sqrt {-1+d^2 x^2}} \, dx}{2 \sqrt {-1+d x} \sqrt {1+d x}}\\ &=-\frac {a \left (1-d^2 x^2\right )}{2 x^2 \sqrt {-1+d x} \sqrt {1+d x}}-\frac {b \left (1-d^2 x^2\right )}{x \sqrt {-1+d x} \sqrt {1+d x}}+\frac {\left (\left (2 c+a d^2\right ) \sqrt {-1+d^2 x^2}\right ) \int \frac {1}{x \sqrt {-1+d^2 x^2}} \, dx}{2 \sqrt {-1+d x} \sqrt {1+d x}}\\ &=-\frac {a \left (1-d^2 x^2\right )}{2 x^2 \sqrt {-1+d x} \sqrt {1+d x}}-\frac {b \left (1-d^2 x^2\right )}{x \sqrt {-1+d x} \sqrt {1+d x}}+\frac {\left (\left (2 c+a d^2\right ) \sqrt {-1+d^2 x^2}\right ) \operatorname {Subst}\left (\int \frac {1}{x \sqrt {-1+d^2 x}} \, dx,x,x^2\right )}{4 \sqrt {-1+d x} \sqrt {1+d x}}\\ &=-\frac {a \left (1-d^2 x^2\right )}{2 x^2 \sqrt {-1+d x} \sqrt {1+d x}}-\frac {b \left (1-d^2 x^2\right )}{x \sqrt {-1+d x} \sqrt {1+d x}}+\frac {\left (\left (2 c+a d^2\right ) \sqrt {-1+d^2 x^2}\right ) \operatorname {Subst}\left (\int \frac {1}{\frac {1}{d^2}+\frac {x^2}{d^2}} \, dx,x,\sqrt {-1+d^2 x^2}\right )}{2 d^2 \sqrt {-1+d x} \sqrt {1+d x}}\\ &=-\frac {a \left (1-d^2 x^2\right )}{2 x^2 \sqrt {-1+d x} \sqrt {1+d x}}-\frac {b \left (1-d^2 x^2\right )}{x \sqrt {-1+d x} \sqrt {1+d x}}+\frac {\left (2 c+a d^2\right ) \sqrt {-1+d^2 x^2} \tan ^{-1}\left (\sqrt {-1+d^2 x^2}\right )}{2 \sqrt {-1+d x} \sqrt {1+d x}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.14, size = 82, normalized size = 0.99 \begin {gather*} \frac {\left (d^2 x^2-1\right ) (a+2 b x)+x^2 \sqrt {d^2 x^2-1} \left (a d^2+2 c\right ) \tan ^{-1}\left (\sqrt {d^2 x^2-1}\right )}{2 x^2 \sqrt {d x-1} \sqrt {d x+1}} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(a + b*x + c*x^2)/(x^3*Sqrt[-1 + d*x]*Sqrt[1 + d*x]),x]

[Out]

((a + 2*b*x)*(-1 + d^2*x^2) + (2*c + a*d^2)*x^2*Sqrt[-1 + d^2*x^2]*ArcTan[Sqrt[-1 + d^2*x^2]])/(2*x^2*Sqrt[-1
+ d*x]*Sqrt[1 + d*x])

________________________________________________________________________________________

IntegrateAlgebraic [A]  time = 0.12, size = 107, normalized size = 1.29 \begin {gather*} \left (a d^2+2 c\right ) \tan ^{-1}\left (\frac {\sqrt {d x-1}}{\sqrt {d x+1}}\right )-\frac {d \sqrt {d x-1} \left (\frac {a d (d x-1)}{d x+1}-a d-\frac {2 b (d x-1)}{d x+1}-2 b\right )}{\sqrt {d x+1} \left (\frac {d x-1}{d x+1}+1\right )^2} \end {gather*}

Antiderivative was successfully verified.

[In]

IntegrateAlgebraic[(a + b*x + c*x^2)/(x^3*Sqrt[-1 + d*x]*Sqrt[1 + d*x]),x]

[Out]

-((d*Sqrt[-1 + d*x]*(-2*b - a*d - (2*b*(-1 + d*x))/(1 + d*x) + (a*d*(-1 + d*x))/(1 + d*x)))/(Sqrt[1 + d*x]*(1
+ (-1 + d*x)/(1 + d*x))^2)) + (2*c + a*d^2)*ArcTan[Sqrt[-1 + d*x]/Sqrt[1 + d*x]]

________________________________________________________________________________________

fricas [A]  time = 0.88, size = 69, normalized size = 0.83 \begin {gather*} \frac {2 \, b d x^{2} + 2 \, {\left (a d^{2} + 2 \, c\right )} x^{2} \arctan \left (-d x + \sqrt {d x + 1} \sqrt {d x - 1}\right ) + {\left (2 \, b x + a\right )} \sqrt {d x + 1} \sqrt {d x - 1}}{2 \, x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((c*x^2+b*x+a)/x^3/(d*x-1)^(1/2)/(d*x+1)^(1/2),x, algorithm="fricas")

[Out]

1/2*(2*b*d*x^2 + 2*(a*d^2 + 2*c)*x^2*arctan(-d*x + sqrt(d*x + 1)*sqrt(d*x - 1)) + (2*b*x + a)*sqrt(d*x + 1)*sq
rt(d*x - 1))/x^2

________________________________________________________________________________________

giac [B]  time = 1.35, size = 145, normalized size = 1.75 \begin {gather*} -\frac {{\left (a d^{3} + 2 \, c d\right )} \arctan \left (\frac {1}{2} \, {\left (\sqrt {d x + 1} - \sqrt {d x - 1}\right )}^{2}\right ) + \frac {2 \, {\left (a d^{3} {\left (\sqrt {d x + 1} - \sqrt {d x - 1}\right )}^{6} - 4 \, b d^{2} {\left (\sqrt {d x + 1} - \sqrt {d x - 1}\right )}^{4} - 4 \, a d^{3} {\left (\sqrt {d x + 1} - \sqrt {d x - 1}\right )}^{2} - 16 \, b d^{2}\right )}}{{\left ({\left (\sqrt {d x + 1} - \sqrt {d x - 1}\right )}^{4} + 4\right )}^{2}}}{d} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((c*x^2+b*x+a)/x^3/(d*x-1)^(1/2)/(d*x+1)^(1/2),x, algorithm="giac")

[Out]

-((a*d^3 + 2*c*d)*arctan(1/2*(sqrt(d*x + 1) - sqrt(d*x - 1))^2) + 2*(a*d^3*(sqrt(d*x + 1) - sqrt(d*x - 1))^6 -
 4*b*d^2*(sqrt(d*x + 1) - sqrt(d*x - 1))^4 - 4*a*d^3*(sqrt(d*x + 1) - sqrt(d*x - 1))^2 - 16*b*d^2)/((sqrt(d*x
+ 1) - sqrt(d*x - 1))^4 + 4)^2)/d

________________________________________________________________________________________

maple [C]  time = 0.02, size = 103, normalized size = 1.24 \begin {gather*} -\frac {\sqrt {d x -1}\, \sqrt {d x +1}\, \left (a \,d^{2} x^{2} \arctan \left (\frac {1}{\sqrt {d^{2} x^{2}-1}}\right )+2 c \,x^{2} \arctan \left (\frac {1}{\sqrt {d^{2} x^{2}-1}}\right )-2 \sqrt {d^{2} x^{2}-1}\, b x -\sqrt {d^{2} x^{2}-1}\, a \right ) \mathrm {csgn}\relax (d )^{2}}{2 \sqrt {d^{2} x^{2}-1}\, x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((c*x^2+b*x+a)/x^3/(d*x-1)^(1/2)/(d*x+1)^(1/2),x)

[Out]

-1/2*(d*x-1)^(1/2)*(d*x+1)^(1/2)*csgn(d)^2*(arctan(1/(d^2*x^2-1)^(1/2))*x^2*a*d^2+2*arctan(1/(d^2*x^2-1)^(1/2)
)*x^2*c-2*(d^2*x^2-1)^(1/2)*x*b-(d^2*x^2-1)^(1/2)*a)/(d^2*x^2-1)^(1/2)/x^2

________________________________________________________________________________________

maxima [A]  time = 0.97, size = 61, normalized size = 0.73 \begin {gather*} -\frac {1}{2} \, a d^{2} \arcsin \left (\frac {1}{d {\left | x \right |}}\right ) - c \arcsin \left (\frac {1}{d {\left | x \right |}}\right ) + \frac {\sqrt {d^{2} x^{2} - 1} b}{x} + \frac {\sqrt {d^{2} x^{2} - 1} a}{2 \, x^{2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((c*x^2+b*x+a)/x^3/(d*x-1)^(1/2)/(d*x+1)^(1/2),x, algorithm="maxima")

[Out]

-1/2*a*d^2*arcsin(1/(d*abs(x))) - c*arcsin(1/(d*abs(x))) + sqrt(d^2*x^2 - 1)*b/x + 1/2*sqrt(d^2*x^2 - 1)*a/x^2

________________________________________________________________________________________

mupad [B]  time = 9.89, size = 316, normalized size = 3.81 \begin {gather*} \frac {\frac {a\,d^2\,1{}\mathrm {i}}{32}+\frac {a\,d^2\,{\left (\sqrt {d\,x-1}-\mathrm {i}\right )}^2\,1{}\mathrm {i}}{16\,{\left (\sqrt {d\,x+1}-1\right )}^2}-\frac {a\,d^2\,{\left (\sqrt {d\,x-1}-\mathrm {i}\right )}^4\,15{}\mathrm {i}}{32\,{\left (\sqrt {d\,x+1}-1\right )}^4}}{\frac {{\left (\sqrt {d\,x-1}-\mathrm {i}\right )}^2}{{\left (\sqrt {d\,x+1}-1\right )}^2}+\frac {2\,{\left (\sqrt {d\,x-1}-\mathrm {i}\right )}^4}{{\left (\sqrt {d\,x+1}-1\right )}^4}+\frac {{\left (\sqrt {d\,x-1}-\mathrm {i}\right )}^6}{{\left (\sqrt {d\,x+1}-1\right )}^6}}-c\,\left (\ln \left (\frac {{\left (\sqrt {d\,x-1}-\mathrm {i}\right )}^2}{{\left (\sqrt {d\,x+1}-1\right )}^2}+1\right )-\ln \left (\frac {\sqrt {d\,x-1}-\mathrm {i}}{\sqrt {d\,x+1}-1}\right )\right )\,1{}\mathrm {i}-\frac {a\,d^2\,\ln \left (\frac {{\left (\sqrt {d\,x-1}-\mathrm {i}\right )}^2}{{\left (\sqrt {d\,x+1}-1\right )}^2}+1\right )\,1{}\mathrm {i}}{2}+\frac {a\,d^2\,\ln \left (\frac {\sqrt {d\,x-1}-\mathrm {i}}{\sqrt {d\,x+1}-1}\right )\,1{}\mathrm {i}}{2}+\frac {b\,\sqrt {d\,x-1}\,\sqrt {d\,x+1}}{x}+\frac {a\,d^2\,{\left (\sqrt {d\,x-1}-\mathrm {i}\right )}^2\,1{}\mathrm {i}}{32\,{\left (\sqrt {d\,x+1}-1\right )}^2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a + b*x + c*x^2)/(x^3*(d*x - 1)^(1/2)*(d*x + 1)^(1/2)),x)

[Out]

((a*d^2*1i)/32 + (a*d^2*((d*x - 1)^(1/2) - 1i)^2*1i)/(16*((d*x + 1)^(1/2) - 1)^2) - (a*d^2*((d*x - 1)^(1/2) -
1i)^4*15i)/(32*((d*x + 1)^(1/2) - 1)^4))/(((d*x - 1)^(1/2) - 1i)^2/((d*x + 1)^(1/2) - 1)^2 + (2*((d*x - 1)^(1/
2) - 1i)^4)/((d*x + 1)^(1/2) - 1)^4 + ((d*x - 1)^(1/2) - 1i)^6/((d*x + 1)^(1/2) - 1)^6) - c*(log(((d*x - 1)^(1
/2) - 1i)^2/((d*x + 1)^(1/2) - 1)^2 + 1) - log(((d*x - 1)^(1/2) - 1i)/((d*x + 1)^(1/2) - 1)))*1i - (a*d^2*log(
((d*x - 1)^(1/2) - 1i)^2/((d*x + 1)^(1/2) - 1)^2 + 1)*1i)/2 + (a*d^2*log(((d*x - 1)^(1/2) - 1i)/((d*x + 1)^(1/
2) - 1))*1i)/2 + (b*(d*x - 1)^(1/2)*(d*x + 1)^(1/2))/x + (a*d^2*((d*x - 1)^(1/2) - 1i)^2*1i)/(32*((d*x + 1)^(1
/2) - 1)^2)

________________________________________________________________________________________

sympy [C]  time = 74.80, size = 212, normalized size = 2.55 \begin {gather*} - \frac {a d^{2} {G_{6, 6}^{5, 3}\left (\begin {matrix} \frac {7}{4}, \frac {9}{4}, 1 & 2, 2, \frac {5}{2} \\\frac {3}{2}, \frac {7}{4}, 2, \frac {9}{4}, \frac {5}{2} & 0 \end {matrix} \middle | {\frac {1}{d^{2} x^{2}}} \right )}}{4 \pi ^{\frac {3}{2}}} + \frac {i a d^{2} {G_{6, 6}^{2, 6}\left (\begin {matrix} 1, \frac {5}{4}, \frac {3}{2}, \frac {7}{4}, 2, 1 & \\\frac {5}{4}, \frac {7}{4} & 1, \frac {3}{2}, \frac {3}{2}, 0 \end {matrix} \middle | {\frac {e^{2 i \pi }}{d^{2} x^{2}}} \right )}}{4 \pi ^{\frac {3}{2}}} - \frac {b d {G_{6, 6}^{5, 3}\left (\begin {matrix} \frac {5}{4}, \frac {7}{4}, 1 & \frac {3}{2}, \frac {3}{2}, 2 \\1, \frac {5}{4}, \frac {3}{2}, \frac {7}{4}, 2 & 0 \end {matrix} \middle | {\frac {1}{d^{2} x^{2}}} \right )}}{4 \pi ^{\frac {3}{2}}} - \frac {i b d {G_{6, 6}^{2, 6}\left (\begin {matrix} \frac {1}{2}, \frac {3}{4}, 1, \frac {5}{4}, \frac {3}{2}, 1 & \\\frac {3}{4}, \frac {5}{4} & \frac {1}{2}, 1, 1, 0 \end {matrix} \middle | {\frac {e^{2 i \pi }}{d^{2} x^{2}}} \right )}}{4 \pi ^{\frac {3}{2}}} - \frac {c {G_{6, 6}^{5, 3}\left (\begin {matrix} \frac {3}{4}, \frac {5}{4}, 1 & 1, 1, \frac {3}{2} \\\frac {1}{2}, \frac {3}{4}, 1, \frac {5}{4}, \frac {3}{2} & 0 \end {matrix} \middle | {\frac {1}{d^{2} x^{2}}} \right )}}{4 \pi ^{\frac {3}{2}}} + \frac {i c {G_{6, 6}^{2, 6}\left (\begin {matrix} 0, \frac {1}{4}, \frac {1}{2}, \frac {3}{4}, 1, 1 & \\\frac {1}{4}, \frac {3}{4} & 0, \frac {1}{2}, \frac {1}{2}, 0 \end {matrix} \middle | {\frac {e^{2 i \pi }}{d^{2} x^{2}}} \right )}}{4 \pi ^{\frac {3}{2}}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((c*x**2+b*x+a)/x**3/(d*x-1)**(1/2)/(d*x+1)**(1/2),x)

[Out]

-a*d**2*meijerg(((7/4, 9/4, 1), (2, 2, 5/2)), ((3/2, 7/4, 2, 9/4, 5/2), (0,)), 1/(d**2*x**2))/(4*pi**(3/2)) +
I*a*d**2*meijerg(((1, 5/4, 3/2, 7/4, 2, 1), ()), ((5/4, 7/4), (1, 3/2, 3/2, 0)), exp_polar(2*I*pi)/(d**2*x**2)
)/(4*pi**(3/2)) - b*d*meijerg(((5/4, 7/4, 1), (3/2, 3/2, 2)), ((1, 5/4, 3/2, 7/4, 2), (0,)), 1/(d**2*x**2))/(4
*pi**(3/2)) - I*b*d*meijerg(((1/2, 3/4, 1, 5/4, 3/2, 1), ()), ((3/4, 5/4), (1/2, 1, 1, 0)), exp_polar(2*I*pi)/
(d**2*x**2))/(4*pi**(3/2)) - c*meijerg(((3/4, 5/4, 1), (1, 1, 3/2)), ((1/2, 3/4, 1, 5/4, 3/2), (0,)), 1/(d**2*
x**2))/(4*pi**(3/2)) + I*c*meijerg(((0, 1/4, 1/2, 3/4, 1, 1), ()), ((1/4, 3/4), (0, 1/2, 1/2, 0)), exp_polar(2
*I*pi)/(d**2*x**2))/(4*pi**(3/2))

________________________________________________________________________________________